window = this

const Window =function Window()
{
    throw new TypeError('Illegal constructor')
}
catvm.safefunction(Window);

window.setTimeout = function setTimeout(callback,delay){
    typeof(callback) === 'function' ? callback() : undefined
    typeof(callback) === 'string' ? eval(callback) : undefined
    return 0
}
window.setInterval = function setInterval(callback,delay){
    typeof(callback) === 'function' ? callback() : undefined
    typeof(callback) === 'string' ? eval(callback) : undefined
    return 0
}
// window.setImmediate = function setImmediate(callback,delay){
//     typeof(callback) === 'function' ? callback() : undefined
//     typeof(callback) === 'string' ? eval(callback) : undefined
//     return 0
// }
// window.clearImmediate = function clearImmediate(callback,delay){
//     typeof(callback) === 'function' ? callback() : undefined
//     typeof(callback) === 'string' ? eval(callback) : undefined
//     return 0
// }



catvm.safefunction(window.setTimeout );
catvm.safefunction(window.setInterval);

window.postMessage= function postMessage(){

}
catvm.safefunction(window.postMessage);



Window.prototype.PERSISTENT = 1
Window.prototype.TEMPORARY = 0







window.open =function open(){}
window.chrome = catvm.proxy(class chrome{})
window.DeviceOrientationEvent = function DeviceOrientationEvent(){}
window.DeviceMotionEvent = function DeviceMotionEvent(){}
catvm.safefunction(window.open);
catvm.safefunction(window.DeviceOrientationEvent);
catvm.safefunction(window.DeviceMotionEvent);






window.localStorage = class localStorage{}
window.localStorage.getItem = function getItem(){}
window.localStorage.setItem = function getItem(){}
catvm.safefunction(window.localStorage.getItem );
catvm.safefunction(window.localStorage.setItem );
catvm.proxy(window.localStorage)
Window.prototype.__proto__ = windowProperties.prototype;
window.__proto__ = Window.prototype

Object.defineProperties(Window.prototype,{
    [Symbol.toStringTag]:{
        value:'Window',
        configurable:true,
    }
})

//window.MessageChannel=function(){return catvm.proxy({port1:catvm.proxy({onmessage:null}),port2:catvm.proxy({onmessage:null})},"MutationObserver")}
window.postMessage= function postMessage(){}
window.queueMicrotask=function queueMicrotask(){}
window.XMLHttpRequest=function XMLHttpRequest(){}
catvm.safefunction(window.postMessage)
catvm.safefunction(window.queueMicrotask)
catvm.safefunction(window.XMLHttpRequest)

window.MutationObserver=function(){return catvm.proxy({observe:function (){}},"MutationObserver")}
window.PromiseRejectionEvent=function(){return catvm.proxy({},"PromiseRejectionEvent")}
window.dispatchEvent=function(){return catvm.proxy({},"dispatchEvent")}
window.CSSRuleList=function(){return catvm.proxy({},"CSSRuleList")}
window.CSSStyleDeclaration=function(){return catvm.proxy({},"CSSStyleDeclaration")}
window.DOMRectList=function(){return catvm.proxy({},"DOMRectList")}
window.DOMStringList=function(){return catvm.proxy({},"DOMStringList")}
window.DOMTokenList=function(){return catvm.proxy({},"DOMTokenList")}
window.DataTransferItemList=function(){return catvm.proxy({},"DataTransferItemList")}
window.FileList=function(){return catvm.proxy({},"FileList")}
window.HTMLAllCollection=function(){return catvm.proxy({},"HTMLAllCollection")}
window.HTMLCollection=function(){return catvm.proxy({},"HTMLCollection")}
window.HTMLFormElement=function(){return catvm.proxy({},"HTMLFormElement")}
window.HTMLSelectElement=function(){return catvm.proxy({},"HTMLSelectElement")}
window.MediaList=function(){return catvm.proxy({},"MediaList")}
window.MimeTypeArray=function(){return catvm.proxy({},"MimeTypeArray")}
window.NamedNodeMap=function(){return catvm.proxy({},"NamedNodeMap")}
window.NodeList=function(){return catvm.proxy({},"NodeList")}

window.Plugin=function(){return catvm.proxy({},"Plugin")}
window.PluginArray=function(){return catvm.proxy({},"PluginArray")}
window.SVGLengthList=function(){return catvm.proxy({},"SVGLengthList")}
window.SVGNumberList=function(){return catvm.proxy({},"SVGNumberList")}

window.SVGPointList=function(){return catvm.proxy({},"SVGPointList")}
window.SVGStringList=function(){return catvm.proxy({},"SVGStringList")}
window.SVGTransformList=function(){return catvm.proxy({},"SVGTransformList")}
window.SourceBufferList=function(){return catvm.proxy({},"SourceBufferList")}
window.StyleSheetList=function(){return catvm.proxy({},"StyleSheetList")}
window.TextTrackCueList=function(){return catvm.proxy({},"TextTrackCueList")}
window.TextTrackList=function(){return catvm.proxy({},"TextTrackList")}
window.TouchList=function(){return catvm.proxy({},"TouchList")}
window.regeneratorRuntime=catvm.proxy({},"regeneratorRuntime")

window.crypto=catvm.proxy({
    getRandomValues:function getRandomValues(arr) {
    if (!(arr instanceof Uint8Array || arr instanceof Uint16Array || arr instanceof Uint32Array)) {
        throw new TypeError('Expected a TypedArray');
    }

    for (let i = 0; i < arr.length; i++) {
        arr[i] = Math.floor(Math.random() * (arr.constructor.BYTES_PER_ELEMENT === 1 ? 256 : (arr.constructor.BYTES_PER_ELEMENT === 2 ? 65536 : 4294967296)));
    }

    return catvm.proxy(arr);
}
},'crypto')
window.performance=catvm.proxy({
    timing:function (){ return catvm.proxy({})},
    getEntries:function (){return catvm.proxy({})},

},'performance')
// window.CSSValueList=catvm.proxy({prototype:catvm.proxy({})},"regeneratorRuntime")
// window.ClientRectList=catvm.proxy({prototype:catvm.proxy({})},"regeneratorRuntime")
// window.PaintRequestList=catvm.proxy({prototype:catvm.proxy({})},"regeneratorRuntime")
// window.SVGPathSegList=catvm.proxy({prototype:catvm.proxy({})},"regeneratorRuntime")

window.outerWidth=1536
window.outerHeight=864
window.devicePixelRatio=1.25
window.React=catvm.proxy({})




window.Promise_=window.Promise
// window.Promise=function Promise(){
//     var a=window.Promise_()
//     return a
// }


window = catvm.proxy(window)
globalThis=window
globalThis=catvm.proxy(global)

